<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>乐淘搜索列表(键盘敲难,月薪过o.o4亿)</title>
    <!-- 引入font文件 -->
    <link rel="stylesheet" href="./assets/fontAwesome/css/font-awesome.css">
    <!-- 引入mui样式 -->
    <link rel="stylesheet" href="./assets/mui/css/mui.css">
    <!-- 公共样式 -->
    <link rel="stylesheet" href="./css/common.css">
    <!-- 首页样式 -->
    <link rel="stylesheet" href="./css/searchList.css">
</head>

<body>
    <!-- 头部 -->
    <!-- mui-action-back 类 可以实现返回上一页  -->
    <header id="lt_header" class="mui-bar mui-bar-nav">
        <h1 class="mui-title">搜索列表</h1>
        <!-- <a class="fa fa-search mui-pull-right"></a> -->
        <a href="javascript:;" class="mui-action-back fa fa-arrow-left h-left"></a>
    </header>

    <!-- 内容 -->
    <div class="lt_view">
        <div class="lt_content">
        
       <div class="search">
            <!-- 搜索按钮 -->
            <div class="search_form">
                <input id="search_inp" placeholder="搜索你喜欢的商品" type="text">
                <button id="search_btn">搜索</button>
            </div>
       </div>

       <!-- 排序栏 -->
       <div class="sort_bar">
           <a href="javascript:;">
               上架时间
               <span class="fa fa-angle-down"></span>
           </a>
           <a data-sortkey="price" href="javascript:;">
               价格
               <span class="fa fa-angle-down"></span>
           </a>
           <a data-sortkey="num" href="javascript:;">
               销量
               <span class="fa fa-angle-down"></span>
           </a>
           <a href="javascript:;">
               折扣
               <span class="fa fa-angle-down"></span>
           </a>
       </div>

       <!-- 商品列表 -->
       <div class="goods_list">
       <ul></ul>
       </div>
    </div>
    </div>


    <!-- 尾部 -->
    <div class="lt_footer">
        <a href="./index.html">
            <span class="fa fa-home"></span>
            <div class="link-name">首页</div>
        </a>
        <a href="./category.html" class="active">
            <span class="fa fa-bars"></span>
            <div class="link-name">分类</div>
        </a>
        <a href="javascript:;">
            <span class="fa fa-shopping-cart"></span>
            <div class="link-name">购物车</div>
        </a>
        <a href="javascript:;">
            <span class="fa fa-user"></span>
            <div class="link-name">会员中心</div>
        </a>
    </div>


</body>
<!-- mui.js 不依赖其他 -->
<script src="./assets/mui/js/mui.js"></script>
<!-- 方便我们自己开发 zepto -->
<script src="./assets/zepto/zepto.js"></script>
<!-- 公共的js -->
<script src="./js/common.js"></script>
<!-- 自己的js index.js -->
<script src="./js/searchList.js"></script>
<!-- 引入模板文件 -->
<script src="./assets/arttemplate/template-web.js"></script>

<!-- 模板 -->
<script type="text/template" id="mainTpl"> 
             {{each arr value index}}
                <li>
                    <img src="{{value.pic[0].picAddr}}" alt="">
                    <div class="good-name">{{value.proName}}</div>
                    <div class="good-price">
                        <span class="new_price">¥{{value.price}}</span>
                        <del>¥{{value.oldPrice}}</del>
                    </div>
                    <div>{{value.num}}</div>
                    <a href="./product.html?productId={{value.id}}" type="button" class="mui-btn mui-btn-primary">立即购买</a>
                </li>
                {{/each}}
</script>

</html>